home *** CD-ROM | disk | FTP | other *** search
/ Workbench Design / WB Collection.iso / workbench werkzeuge / memory & system tools / vmm / installvmm / deutsch < prev    next >
Text File  |  1996-04-07  |  14KB  |  411 lines

  1. ; VMM Installer script by Martin Apel
  2. ; Installation script for VMM 3.3
  3.  
  4. (set @app-name "VMM")
  5.  
  6. (welcome "        Willkommen zur Installation von VMM"
  7.          "       Virtueller Speicher für Amigas mit MMU\n\n"
  8.          "        Copyright 1993-95 Martin Apel\n\n"
  9.          "Novice   installiert alles außer den Entwicklerdateien.\n"
  10.          "Advanced installiert alles ohne Bestätigung.\n"
  11.          "Expert   installiert alles mit Bestätigung jeder Aktion.\n")
  12.  
  13. (if (= 0 @user-level) ; then
  14.     (set install_level %000111)
  15. ;else
  16.     (set install_level (askoptions (prompt "Was wollen Sie installieren ?")
  17.                                    (help   @askoptions-help)
  18.                                    (choices "VMM" "Icons" "Dokumente" "Entwicklerdateien" "Zusatzprogramme" "Rexx Skripte")))
  19. )
  20.  
  21. (set def_help "\n\nWenn Sie mehr Hilfe benötigen, sehen Sie in \"VMM.guide\"\n\n")
  22.  
  23. (set my_level @user-level)
  24. (user 2)
  25. (set vmmdest
  26.     ;get destination directory for "VMM"
  27.      (askdir (prompt "Wählen Sie das Verzeichnis für VMM (und Zusatzprogramme) aus.")
  28.              (help   "Dies sollte ein Verzeichnis sein, in dem Sie VMM einfach von "
  29.                      "der Workbench oder der Shell aus starten können." def_help
  30.                      @askdir-help)
  31.              (default @default-dest)
  32.              (disk)
  33.      )
  34. )
  35. (user my_level)
  36.  
  37. (set copy_vmm   (BITAND %000001 install_level))
  38. (set copy_icons (BITAND %000010 install_level))
  39. (set copy_docs  (BITAND %000100 install_level))
  40. (set copy_dev   (BITAND %001000 install_level))
  41. (set copy_tools (BITAND %010000 install_level))
  42. (set copy_rexx  (BITAND %100000 install_level))
  43.  
  44. ; Copy VMM files
  45.  
  46. (if copy_vmm
  47.   (
  48.     (set @default-dest vmmdest)
  49.     (set vmmtacked (tackon vmmdest "VMM"))
  50.  
  51.     ; ask, if we want to overwrite the old VMM if it exists
  52.     (set overwrite 1)
  53.     (if (exists "L:VMM-Handler")
  54.       (
  55.         (set old_version (getversion "l:VMM-Handler"))
  56.         (set old_ver (/ old_version 65536))
  57.         (set old_rev (- old_version (* old_ver 65536)))
  58.  
  59.         (set new_version (getversion "/l/VMM-Handler_4K"))
  60.         (set new_ver (/ new_version 65536))
  61.         (set new_rev (- new_version (* new_ver 65536)))
  62.  
  63.         (set overwrite (askbool (prompt "\nSie haben VMM "
  64.                                          old_ver "." old_rev " schon installiert"
  65.                                         ".\nWollen Sie es mit VMM "
  66.                                          new_ver "." new_rev " überschreiben ?\n")
  67.                                 (help def_help @askbool-help)
  68.                                 (default 1)
  69.                                 (choices "Ja" "Nein"))
  70.  
  71.         )
  72.       )
  73.     )
  74.  
  75.     (if overwrite
  76.         (
  77.            ; detect the pagesize (4K or 8K)
  78.            (set pagesize (run "/tools/ShowPageSize"))
  79.  
  80.            (select pagesize
  81.              (abort "Interner Fehler im Installer Skript")
  82.              ((set info_string "Eine Seitengröße von 4K ist auf Ihrem System möglich")
  83.               (set default_choice 0))
  84.              ((set info_string "Eine Seitengröße von 8K ist auf Ihrem System möglich")
  85.               (set default_choice 1))
  86.              ((set info_string "Sowohl 4K als auch 8K-Seiten sind auf Ihrem System möglich")
  87.               (set default_choice 0))
  88.            )
  89.  
  90.            (set my_choice (askchoice (prompt "\nWählen Sie die Seitengröße:\n\n"
  91.                                            info_string ".\n")
  92.                                    (help   def_help @askchoice-help)
  93.                                    (choices "4K Seiten" "8K Seiten")
  94.                                    (default default_choice))
  95.            )
  96.  
  97.            (select my_choice
  98.             (set sizestr "4K")
  99.             (set sizestr "8K")
  100.            )
  101.  
  102.            ; copy the new VMM file to the destination directory
  103.            (if copy_icons
  104.               ; then
  105.                 (copyfiles (prompt ("\nKopiere VMM nach %s." vmmdest))
  106.                            (help   def_help @copyfiles-help)
  107.                            (optional "oknodelete")
  108.                            (optional "askuser")
  109.                            (source "/")
  110.                            (choices  "VMM")
  111.                            (dest     vmmdest)
  112.                            (infos)
  113.                            (confirm)
  114.                 )
  115.               ; else
  116.                 (copyfiles (prompt ("\nKopiere VMM nach %s." vmmdest))
  117.                            (help   def_help @copyfiles-help)
  118.                            (optional "oknodelete")
  119.                            (optional "askuser")
  120.                            (source "/")
  121.                            (choices  "VMM")
  122.                            (dest     vmmdest)
  123.                            (confirm)
  124.                 )
  125.            )
  126.  
  127.            ; copy the catalog for VMM
  128.            (copyfiles (prompt "\nKopiere VMM.catalog nach LOCALE:catalogs/deutsch.")
  129.                        (help   def_help @copyfiles-help)
  130.                        (optional "oknodelete")
  131.                        (optional "askuser")
  132.                        (source  "/catalogs/deutsch/VMM.catalog")
  133.                        (dest    "LOCALE:catalogs/deutsch")
  134.                        (confirm)
  135.            )
  136.  
  137.  
  138.            ; copy the new VMM-Handler file to l: and rename it as "VMM-Handler"
  139.            (set handler_name (cat "/l/VMM-Handler_" sizestr))
  140.            (copyfiles (prompt "\nKopiere VMM-Handler nach L:.")
  141.                       (help   def_help @copyfiles-help)
  142.                       (optional "oknodelete")
  143.                       (optional "askuser")
  144.                       (source  handler_name)
  145.                       (dest    "l:")
  146.                       (newname "VMM-Handler")
  147.                       (confirm)
  148.            )
  149.  
  150.            ; copy the catalog for the VMM-handler
  151.            (copyfiles (prompt "\nKopiere VMM-Handler.catalog nach LOCALE:catalogs/deutsch.")
  152.                        (help   def_help @copyfiles-help)
  153.                        (optional "oknodelete")
  154.                        (optional "askuser")
  155.                        (source  "/catalogs/deutsch/VMM-Handler.catalog")
  156.                        (dest    "LOCALE:catalogs/deutsch")
  157.                        (confirm)
  158.            )
  159.  
  160.         )
  161.      )
  162.  
  163.  
  164.  
  165.     ; ask, if we want to overwrite the old preferences file
  166.     ; default: do overwrite preferences file
  167.     (set overwrite 1)
  168.     (if (exists "envarc:VMM.prefs")
  169.         (if (= 0 (askbool (prompt "\nSie haben schon eine Einstellungsdatei für VMM installiert.\nWollen Sie sie überschreiben ?\n\n")
  170.                      (help "Wenn Sie die Einstellungsdatei nicht überschreiben lassen, so können Sie sie im nächsten Schritt konvertieren lassen" @askbool-help)
  171.                      (default 0)
  172.                      (choices "Ja" "Nein")))
  173.               (set overwrite 0)
  174.         )
  175.     )
  176.  
  177.     (if overwrite
  178.       (
  179.         ; copy the new preferences file to env: and envarc:
  180.         (copyfiles (prompt ("\nKopiere VMM.prefs nach env:\n"))
  181.                    (help   def_help @copyfiles-help)
  182.                    (optional "oknodelete")
  183.                    (optional "askuser")
  184.                    (source  "/env/VMM.prefs")
  185.                    (dest    "env:")
  186.                    (confirm)
  187.         )
  188.         (copyfiles (prompt ("\nKopiere VMM.prefs nach envarc:\n"))
  189.                    (help   def_help @copyfiles-help)
  190.                    (optional "oknodelete")
  191.                    (optional "askuser")
  192.                    (source  "/env/VMM.prefs")
  193.                    (dest    "envarc:")
  194.                    (confirm)
  195.         )
  196.       )
  197.     ; else
  198.       (if (= 1 (askbool (prompt "Das Format der Einstellungsdatei hat sich seit V2.1 geändert\nWollen Sie, daß es konvertiert wird ?"
  199.                      (help def_help @askbool-help)
  200.                      (default 1)
  201.                      (choices "Ja" "Nein"))))
  202.         (run "/tools/ConvVMMCfg")
  203.       )
  204.     )
  205.   )
  206. )
  207.  
  208. ; Copy docs
  209.  
  210. (if copy_docs
  211.     (
  212.       ;get destination directory for "VMM.guide"
  213.       (set doc_dir (tackon vmmdest "doc"))
  214.  
  215.       (if (AND (= 0 @user-level) (NOT (exists doc_dir)))
  216.           ; then
  217.           (makedir doc_dir (infos))
  218.       )
  219.  
  220.       (set vmmdocs
  221.            (askdir (prompt "Wählen Sie das Verzeichnis für die Dokumentation aus\n.")
  222.                    (help   "Dies sollte das Verzeichnis sein, in dem Sie normalerweise Ihre Dokumentation aufbewahren.\n\n"
  223.                            def_help @askdir-help)
  224.                    (default doc_dir)
  225.                    (newpath)
  226.                    (disk)
  227.            )
  228.       )
  229.  
  230.       (if copy_dev
  231.         (if copy_icons
  232.            ; then
  233.            (copyfiles (prompt ("\nKopiere Dokumentation"))
  234.                       (help   def_help @copyfiles-help)
  235.                       (optional "oknodelete")
  236.                       (optional "askuser")
  237.                       (source  "/doc")
  238.                       (choices "VMM.guide" "VMM_Rexx.guide" "VMMTools.guide" "VMM_lib.doc")
  239.                       (dest    vmmdocs)
  240.                       (infos)
  241.                       (confirm)
  242.            )
  243.            ; else
  244.            (copyfiles (prompt ("\nKopiere Dokumentation"))
  245.                       (help   def_help @copyfiles-help)
  246.                       (optional "oknodelete")
  247.                       (optional "askuser")
  248.                       (source  "/doc")
  249.                       (choices "VMM.guide" "VMM_Rexx.guide" "VMMTools.guide" "VMM_lib.doc")
  250.                       (dest    vmmdocs)
  251.                       (confirm)
  252.            )
  253.         )
  254.       ; else
  255.         (if copy_icons
  256.             ; then
  257.               (copyfiles (prompt ("\nKopiere VMM.guide nach " vmmdocs "."))
  258.                          (help   def_help @copyfiles-help)
  259.                          (optional "oknodelete")
  260.                          (optional "askuser")
  261.                          (source  "/doc")
  262.                          (choices "VMM.guide" "VMM_Rexx.guide" "VMMTools.guide")
  263.                          (dest    vmmdocs)
  264.                          (infos)
  265.                          (confirm)
  266.               )
  267.             ; else
  268.               (copyfiles (prompt ("\nKopiere VMM.guide nach " vmmdocs "."))
  269.                          (help   def_help @copyfiles-help)
  270.                          (optional "oknodelete")
  271.                          (optional "askuser")
  272.                          (source  "/doc")
  273.                          (choices "VMM.guide" "VMM_Rexx.guide" "VMMTools.guide")
  274.                          (dest    vmmdocs)
  275.                          (confirm)
  276.               )
  277.         )
  278.       )
  279.     )
  280. )
  281.  
  282. ; Copy developer files
  283.  
  284. (if copy_dev
  285.     (
  286.       (copylib (prompt ("\nKopiere VMM.library nach LIBS:."))
  287.                (help   def_help @copyfiles-help)
  288.                (optional "oknodelete")
  289.                (optional "askuser")
  290.                (source  "/Developer/libs/VMM.library")
  291.                (dest    "libs:")
  292.                (confirm)
  293.       )
  294.  
  295.       (if (exists ("fd:") (noreq))
  296.           ; then
  297.             (set fd_dir "fd:")
  298.           ; else
  299.             (set fd_dir
  300.                  (askdir (prompt "Wählen Sie das Verzeichnis für die FD-Datei aus.")
  301.                          (help   def_help  @askdir-help)
  302.                          (default "SYS:")
  303.                          (disk)
  304.                  )
  305.             )
  306.       )
  307.  
  308.       (if (exists ("include:") (noreq))
  309.           ; then
  310.             (set inc_dir "include:")
  311.           ; else
  312.             (set inc_dir 
  313.                  (askdir (prompt "Wählen Sie das Verzeichnis für die Include-Datei aus.")
  314.                          (help   def_help  @askdir-help)
  315.                          (default "SYS:")
  316.                          (disk)
  317.                  )
  318.             )
  319.       )
  320.  
  321.       (if (exists ("lib:") (noreq))
  322.           ; then
  323.             (set lib_dir "lib:")
  324.           ; else
  325.             (set lib_dir
  326.                  (askdir (prompt "Wählen Sie das Verzeichnis für die Lib-Datei aus.")
  327.                          (help   def_help  @askdir-help)
  328.                          (default "SYS:")
  329.                          (disk)
  330.                  )
  331.             )
  332.       )
  333.  
  334.  
  335.       (copyfiles (prompt ("\nKopiere VMM_lib.fd nach " fd_dir "."))
  336.                  (help   def_help @copyfiles-help)
  337.                  (optional "oknodelete")
  338.                  (optional "askuser")
  339.                  (source  "/Developer/fd/")
  340.                  (choices "VMM_lib.fd")
  341.                  (dest    fd_dir)
  342.                  (confirm)
  343.       )
  344.  
  345.       (copyfiles (prompt ("\nKopiere VMM_stat.h nach " inc_dir "."))
  346.                  (help   def_help @copyfiles-help)
  347.                  (optional "oknodelete")
  348.                  (optional "askuser")
  349.                  (source  "/Developer/include/")
  350.                  (choices "VMM_Stat.h")
  351.                  (dest    inc_dir)
  352.                  (confirm)
  353.       )
  354.  
  355.       (copyfiles (prompt ("\nKopiere VMM_lib.lib nach " lib_dir "."))
  356.                  (help   def_help @copyfiles-help)
  357.                  (optional "oknodelete")
  358.                  (optional "askuser")
  359.                  (source  "/Developer/lib/")
  360.                  (choices "VMM_lib.lib")
  361.                  (dest    lib_dir)
  362.                  (confirm)
  363.       )
  364.     )
  365. )
  366.  
  367. ; Copy tools
  368.  
  369. (if copy_tools
  370.   (
  371.   if copy_icons
  372.     ; then
  373.       (copyfiles (prompt ("\nKopiere Zusatzprogramme nach" vmmdest "."))
  374.                  (help   def_help @copyfiles-help)
  375.                  (optional "oknodelete")
  376.                  (optional "askuser")
  377.                  (source  "/tools")
  378.                  (choices "VMMStat" "VMMUsage" "VMMUsageCLI")
  379.                  (dest    vmmdest)
  380.                  (infos)
  381.                  (confirm)
  382.       )
  383.     ; else
  384.       (copyfiles (prompt ("\nKopiere Zusatzprogramme nach " vmmdest "."))
  385.                  (help   def_help @copyfiles-help)
  386.                  (optional "oknodelete")
  387.                  (optional "askuser")
  388.                  (source  "/tools")
  389.                  (choices "VMMStat" "VMMUsage" "VMMUsageCLI")
  390.                  (dest    vmmdest)
  391.                  (confirm)
  392.       )
  393.   )
  394. )
  395.  
  396. ;
  397.  
  398. ; Copy ARexx scripts
  399.  
  400. (if copy_rexx
  401.   (copyfiles (prompt ("\nKopiere ARexx Skripte nach REXX:"))
  402.              (help   def_help @copyfiles-help)
  403.              (optional "oknodelete")
  404.              (optional "askuser")
  405.              (source  "/rexx")
  406.              (choices "stat_on.vmm" "stat_off.vmm" "show.vmm" "hide.vmm")
  407.              (dest    "REXX:")
  408.              (confirm)
  409.   )
  410. )
  411.